package ooday05;

public class EnumDemo {
    public static void main(String[] args) {
        Season[] season = Season.values();
        for (int i = 0; i < season.length; i++) {
            System.out.println(season[i]);
            System.out.println(season[i].getSeasonName());
            System.out.println(season[i].getSeasonDesc());
        }
        Season s = Season.SPRING;
        System.out.println(s);

        switch (s) {
            case SPRING:
                System.out.println(s.getSeasonName() + "很" + s.getSeasonDesc());
                break;
            case SUMMER:
                System.out.println(s.getSeasonName() + "很" + s.getSeasonDesc());
                break;
            case AUTUMN:
                System.out.println(s.getSeasonName() + "很" + s.getSeasonDesc());
                break;
            case WINTER:
                System.out.println(s.getSeasonName() + "很" + s.getSeasonDesc());
                break;
        }
    }
}
